FROM maven:3.5.3 AS builder
WORKDIR /app
COPY ./  .
RUN mvn clean install -DskipTests

FROM openjdk:8-jre
COPY --from=builder /app/target/spring-cloud-eureka-0.0.1-SNAPSHOT.jar .
EXPOSE 8761
CMD ["java","-jar","spring-cloud-eureka-0.0.1-SNAPSHOT.jar"]
